<extend name="Common@Layout:layui-admin"/>
<block name="title"><title>Json列表</title></block>
<block name="style">
<style>
body{padding: 10px;}
</style>
</block>

<block name="main">
	<blockquote class="layui-elem-quote">此功能牛逼到炸天，非技术人员请绕行！</blockquote>
	<div class="my-btn-box">
	    <span class="fl">
	        <a class="layui-btn btn-add btn-default" onclick="open_iframe_dialog('{:U('edit')}','添加JSON',['900px','700px'],0)" id="btn-add-article">添加JSON</a>
	    </span>
	</div>
		
	<div class="layui-form datashow" data-url="{:U('getdata')}" data-to-red="" data-condition="" data-p="" data-row="10">
		<table class="layui-table">
		  <colgroup>
		  	<col width="50">
		    <col width="50">
		    <col width="170">
		    <col>		    
		    <col width="180">
		    <col width="200">
		  </colgroup>
		  <thead>
		    <tr>
        	  <th><input type="checkbox" name="" lay-skin="primary" lay-filter="allChoose"></th>
		      <th>ID</th>
		      <th>key</th>
		      <th>描述</th>
		      <th>修改时间</th>
		      <th>操作</th>
		    </tr> 
		  </thead>
		  <tbody class="data"></tbody>
		</table>
		<div class="page"></div>
		<script class="data-tpl" type="text/html">
						{{#  layui.each(d, function(index, item){ }}
						<tr>
						  <td><input type="checkbox" name="" lay-skin="primary"><div class="layui-unselect layui-form-checkbox" lay-skin="primary"><i class="layui-icon"></i></div></td>
					      <td>{{item.id}}</td>
						  <td>{{item.key}}</td>
						  <td>{{item.desc}}</td>
						  <td>{{item.update_time}}</td>
						  <td>
							<button onclick="open_iframe_dialog('/admin/json/edit/id/{{item.id}}','编辑JSON',['900px','700px'],0)" class="layui-btn layui-btn-small layui-btn-normal">编辑</button>
						    <button class="layui-btn layui-btn-small layui-btn-danger mini_del" data-url="/admin/json/del/ids/{{item.id}}">删除</button>  
						</td>
					    </tr>
						{{#  }); }}
						
						{{#  if(d.length === 0){ }}
  							--- No Data ---
						{{#  } }} 
			</script>
	</div>
</block>

<block name="script">
<script>

</script>
</block>


